// DriveNotes. Copyright (c) 2011, Andrei Senchuk. All rights reserved.
package net.taviscaron.drivenotes.shared.model.entity;

import java.io.Serializable;

/**
 * User entity object
 * @author Andrei Senchuk
 */
public class User implements Serializable {

    private Long id;
    private String name;
    private String surname;
    private String email;
    private String username;
    private String password;
    private String salt;
    private String attributes;

    public User() {

    }

    public String getAttributes() {
        return attributes;
    }

    public void setAttributes(String attributes) {
        this.attributes = attributes;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt;
    }

    public String getSurname() {
        return surname;
    }

    public void setSurname(String surname) {
        this.surname = surname;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    @Override
    public String toString() {
        return String.format("User #%d: name: %s; surname: %s; username: %s;" +
                "password: %s; salt: %s; email: %s; attributes: [%s]", id, name,
                surname, username, password, salt, email, attributes);
    }
}
